package cn.edu.sdjzu.xg.kcsj.domain;

import cn.edu.sdjzu.xg.kcsj.security.User;

import java.io.Serializable;
import java.sql.Date;

public class Activity implements Comparable<Activity>, Serializable {
    private int id;
    private String description;
    private String introduction;
    private int participantsNum;
    private Date startTime;
    private Date endTime;
    private User teacher;
    private User leader;
    private int state;
    private int signedNum;

    public Activity(int id, String description, String introduction,
                    int participantsNum, Date startTime, Date endTime,
                    User teacher, User leader, int state, int signedNum) {
        this.id = id;
        this.description = description;
        this.introduction = introduction;
        this.participantsNum = participantsNum;
        this.startTime = startTime;
        this.endTime = endTime;
        this.teacher = teacher;
        this.leader = leader;
        this.state = state;
        this.signedNum = signedNum;
    }

    public Activity() {
    }


    @Override
    public int compareTo(Activity o) {
        return this.id - o.id;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public String getIntroduction() {
        return introduction;
    }

    public void setIntroduction(String introduction) {
        this.introduction = introduction;
    }

    public int getParticipantsNum() {
        return participantsNum;
    }

    public void setParticipantsNum(int participantsNum) {
        this.participantsNum = participantsNum;
    }

    public Date getStartTime() {
        return startTime;
    }

    public void setStartTime(Date startTime) {
        this.startTime = startTime;
    }

    public Date getEndTime() {
        return endTime;
    }

    public void setEndTime(Date endTime) {
        this.endTime = endTime;
    }

    public User getTeacher() {
        return teacher;
    }

    public void setTeacher(User teacher) {
        this.teacher = teacher;
    }

    public User getLeader() {
        return leader;
    }

    public void setLeader(User leader) {
        this.leader = leader;
    }

    public int getState() {
        return state;
    }

    public void setState(int state) {
        this.state = state;
    }

    public int getSignedNum() {
        return signedNum;
    }

    public void setSignedNum(int signedNum) {
        this.signedNum = signedNum;
    }

    @Override
    public String toString() {
        return "Activity{" +
                "id=" + id +
                ", description='" + description + '\'' +
                ", introduction='" + introduction + '\'' +
                ", participantsNum=" + participantsNum +
                ", startTime=" + startTime +
                ", endTime=" + endTime +
                ", teacher=" + teacher +
                ", leader=" + leader +
                ", state=" + state +
                ", signedNum=" + signedNum +
                '}';
    }
}
